<%@page isELIgnored="false" import="java.net.*" %>
<%@taglib prefix="tiles" uri="struts-tiles" %>
<%@taglib prefix="html" uri="struts-html" %>
<%@taglib prefix="bean" uri="struts-bean" %>
<%@taglib prefix="c" uri="jstl" %>
<%@taglib prefix="fn" uri="jstl-fn" %>
					
<%@page import="com.mastercard.assets.web.util.to.UserLogin"%><div id="bodyContent">
						<h1>Crear Alarma</h1>
						
						<html:form action='/TareasAgregarRegistrar' method='post' styleId="FormaAgregar">
						<html:hidden property="cveFlujo" />
						<html:hidden property="cveTarea" />
						<html:hidden property="cargar" styleId="cargar" />
						<html:hidden property="operation" styleId="operation" value="0" />
						<html:hidden property="page" value="4" />
						<div onclick="location.href='${URLBase}Flujos.do';" style="display: inline; color: blue; font-size: 12px;" onmouseover="this.style.textDecoration='underline';this.style.cursor='pointer';" onmouseout="this.style.textDecoration='none';this.style.cursor='default';" >Flujos</div><div style="display: inline; color: black; font-size: 12px;" > > </div>
						<div onclick="document.getElementById('operation').value=3;document.getElementById('FormaAgregar').submit( );" style="display: inline; color: blue; font-size: 12px;" onmouseover="this.style.textDecoration='underline';this.style.cursor='pointer';" onmouseout="this.style.textDecoration='none';this.style.cursor='default';" >Tareas del Flujo (${Tarea.tblFlujo.nombre})</div><div style="display: inline; color: black; font-size: 12px;" > > </div>
						<div onclick="document.getElementById( 'operation' ).value='17';document.getElementById('FormaAgregar').submit( );" style="display: inline; color: blue; font-size: 12px;" onmouseover="this.style.textDecoration='underline';this.style.cursor='pointer';" onmouseout="this.style.textDecoration='none';this.style.cursor='default';" >Alarmas de la Tarea (${Tarea.nombre})</div><div style="display: inline; color: black; font-size: 12px;" > > </div>
						<div style="display: inline; color: black; font-size: 12px;"  >Nueva Alarma para la Tarea (${Tarea.nombre})</div>
						<br/>
						<br/>
						<center>
						<div class='errors'>
						<html:errors/>
						<br/>
						${UserLogin.messageError}
						</div>
						
						<table class="TablaCatalogosNuevoTipoCuenta">
							<thead>
								<tr>
									<th>
										Nueva Alarma para la Tarea [${Tarea.nombre}]
									</td>
								</tr>
							</thead>
							<tr>
								<td>
									<br/>
									<table class='TablaCatalogosFields' border="0" style="width: 650px;">
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Alerta" />
											</td>
											<td class='TDField'>
												<html:select property="cveAlerta" styleClass="selectInput">
													<html:option value="0"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Alerta.0"/></html:option>
													<html:options collection="Alertas" labelProperty="nombre" property="cveAlerta" />
												</html:select>
											</td>
										</tr>
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Role" />
											</td>
											<td class='TDField'>
												<html:select property="cveRole" styleClass="selectInput" onchange="document.getElementById( 'operation' ).value='16';document.getElementById( 'cargar' ).value='1';document.getElementById( 'FormaAgregar' ).submit( ) ;">
													<html:option value="0"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Role.0"/></html:option>
													<html:options collection="Roles" labelProperty="nombre" property="cveRole" />
												</html:select>
												&nbsp;
											</td>
										</tr>
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Nivel" />
											</td>
											<td class='TDField'>
<c:if test="${Niveles ne NULL}">
												<html:select property="cveNivel" styleClass="selectInput">
													<html:option value="0"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Nivel.0"/></html:option>
													<html:options collection="Niveles" labelProperty="nombre" property="cveNivel" />
												</html:select>
</c:if>
												&nbsp;
											</td>
										</tr>
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Tipo" />
											</td>
											<td class='TDField'>
												<html:select property="tipoAlerta" styleClass="selectInput" >
													<html:option value="1"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Tipo.1"/></html:option>
													<html:option value="2"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Tipo.2"/></html:option>
													<html:option value="3"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Tipo.3"/></html:option>
												</html:select>
											</td>
										</tr>
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Correo" />
											</td>
											<td class='TDField'>
												<html:text property="email" styleClass='TextField' />
											</td>
										</tr>
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.TipoAlarma" />
											</td>
											<td class='TDField'>
												<html:select property="tipoAlarma" styleClass="selectInput" >
													<html:option value="1"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.TipoAlarma.1"/></html:option>
													<html:option value="2"><bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.TipoAlarma.2"/></html:option>
												</html:select>
											</td>
										</tr>
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Dias" />
											</td>
											<td class='TDField'>
												<html:text property="dias" styleClass='TextField' />
											</td>
										</tr>
										<tr>
											<td class='TDLabel'>
												<bean:message key="com.mastercard.assets.web.modules.alarmas.add.messages.Hora" />
											</td>
											<td class='TDField'>
												<html:select property="horas" styleClass='selectInput' >
													<option value="0" <c:if test="${TareasOperationForm.horas eq 0}">selected="selected"</c:if> >00</option>
													<option value="1" <c:if test="${TareasOperationForm.horas eq 1}">selected="selected"</c:if> >01</option>
													<option value="2" <c:if test="${TareasOperationForm.horas eq 2}">selected="selected"</c:if> >02</option>
													<option value="3" <c:if test="${TareasOperationForm.horas eq 3}">selected="selected"</c:if> >03</option>
													<option value="4" <c:if test="${TareasOperationForm.horas eq 4}">selected="selected"</c:if> >04</option>
													<option value="5" <c:if test="${TareasOperationForm.horas eq 5}">selected="selected"</c:if> >05</option>
													<option value="6" <c:if test="${TareasOperationForm.horas eq 6}">selected="selected"</c:if> >06</option>
													<option value="7" <c:if test="${TareasOperationForm.horas eq 7}">selected="selected"</c:if> >07</option>
													<option value="8" <c:if test="${TareasOperationForm.horas eq 8}">selected="selected"</c:if> >08</option>
													<option value="9" <c:if test="${TareasOperationForm.horas eq 9}">selected="selected"</c:if> >09</option>
													<option value="10" <c:if test="${TareasOperationForm.horas eq 10}">selected="selected"</c:if> >10</option>
													<option value="11" <c:if test="${TareasOperationForm.horas eq 11}">selected="selected"</c:if> >11</option>
													<option value="12" <c:if test="${TareasOperationForm.horas eq 12}">selected="selected"</c:if> >12</option>
													<option value="13" <c:if test="${TareasOperationForm.horas eq 13}">selected="selected"</c:if> >13</option>
													<option value="14" <c:if test="${TareasOperationForm.horas eq 14}">selected="selected"</c:if> >14</option>
													<option value="15" <c:if test="${TareasOperationForm.horas eq 15}">selected="selected"</c:if> >15</option>
													<option value="16" <c:if test="${TareasOperationForm.horas eq 16}">selected="selected"</c:if> >16</option>
													<option value="17" <c:if test="${TareasOperationForm.horas eq 17}">selected="selected"</c:if> >17</option>
													<option value="18" <c:if test="${TareasOperationForm.horas eq 18}">selected="selected"</c:if> >18</option>
													<option value="19" <c:if test="${TareasOperationForm.horas eq 19}">selected="selected"</c:if> >19</option>
													<option value="20" <c:if test="${TareasOperationForm.horas eq 20}">selected="selected"</c:if> >20</option>
													<option value="21" <c:if test="${TareasOperationForm.horas eq 21}">selected="selected"</c:if> >21</option>
													<option value="22" <c:if test="${TareasOperationForm.horas eq 22}">selected="selected"</c:if> >22</option>
													<option value="23" <c:if test="${TareasOperationForm.horas eq 23}">selected="selected"</c:if> >23</option>
												</html:select>
											</td>
										</tr>
										<tr>
											<td colspan='2' class='TDButton'>
												<html:submit value='Cancelar' onclick="document.getElementById( 'operation' ).value='17';return true ;" styleClass="ButtonSubmit" />
												&nbsp;
												<html:submit value='Generar' onclick="document.getElementById( 'operation' ).value='18';return true ;" styleClass="ButtonSubmit" />
											</td>
										</tr>
									</table>
								</td>
							</tr>
						</table>
						</center>
						</html:form>
					</div>
					<div id="footContent"></div>
<%
	UserLogin user = ( UserLogin ) request.getSession( ).getAttribute( "UserLogin" ) ;
	user.clearMessageError( ) ;
%>
